﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;

/* Generated  */
namespace EDMXParserV1
{
        [Serializable]
    public class FunctionImportMapping
    {
        public String FunctionImportName { get; set; }

        public String FunctionName { get; set; }

        public ResultMapping ResultMapping { get; set; }

        public static FunctionImportMapping New(System.Xml.XmlNode Node)
        {
            FunctionImportMapping FunctionImportMapping = new FunctionImportMapping();

            foreach (XmlAttribute Attribute in Node.Attributes)
            {
                switch (Attribute.Name)
                {
                    case "FunctionImportName":
                        FunctionImportMapping.FunctionImportName = Attribute.Value;
                        break;
                    case "FunctionName":
                        FunctionImportMapping.FunctionName = Attribute.Value;
                        break;
                    default:
                        Globals.AttributeSwitchCoder(Attribute);
                        break;
                }

            }

            foreach (XmlNode ChildNode in Node.ChildNodes)
            {
                switch (ChildNode.Name)
                {
                    case "ResultMapping":
                        ResultMapping ResultMapping = ResultMapping.New(ChildNode);
                        FunctionImportMapping.ResultMapping = ResultMapping;
                        break;
                    default:
                        Globals.NodeSwitchCoder(ChildNode);
                        break;
                }
            }

            return FunctionImportMapping;

        }
    }
}
